#include "Character.hpp"

Character::Character(){
}

void Character::bind(lua_State* luaState){

	luabind::module(luaState)[
        luabind::class_<Character>("CharacterEntity")
			.def_readonly("index", &Character::index)
			.def_readwrite("x", &Character::x)
            .def_readwrite("y", &Character::y)
			.def_readwrite("width", &Character::cWidth)
			.def_readwrite("height", &Character::cHeight)
			.def_readwrite("xOffset", &Character::cxOffset)
			.def_readwrite("yOffset", &Character::cyOffset)
			.def_readwrite("maxVelocityX", &Character::maxVelocityX)
			.def_readwrite("maxVelocityY", &Character::maxVelocityY)
			.def_readwrite("acceleration", &Character::acceleration)
            .def_readwrite("hasScript", &Character::hasScript)
            .def_readwrite("updateable", &Character::updateable)
			.def("setMove", &Character::setMove)
			.enum_("constant")[
				luabind::value("North", Entity::dir_N),
				luabind::value("East", Entity::dir_E),
				luabind::value("South", Entity::dir_S),
				luabind::value("West", Entity::dir_W)
			]
    ];
}

void Character::push(lua_State* luaState){
	luabind::object o = luabind::object(luaState, this);
    o.push(luaState);
}

void Character::update(){

}
